﻿#ifndef DELAY_H
#define DELAY_H
#include <QDebug>
#include <QTime>
#include <QTimer>

#include "operation.h"

class Delay : public Operation
{
    Q_OBJECT
public:
    explicit Delay(QObject *parent = nullptr);

public:
    virtual void run() override;

private:
    int m_nDuration; //毫秒

public:
    virtual void writeXML(QXmlStreamWriter &writer) override;
    virtual void readFromXML(QXmlStreamReader &reader) override;
    virtual QString getClassName() override;

    int nDuration() const;
    void setNDuration(int newNDuration);
};

#endif // DELAY_H
